#ifndef __COMMAND_H
#define __COMMAND_H

#include "include.h"

#define DATE_BUFFER_SIZE    20
#define CMD_BUFFER_SIZE     256



typedef struct 
{  
    char earliest_file[MAX_PATH_LENGTH];  
    char latest_file[MAX_PATH_LENGTH];  
} VideoFilePaths;

void* start_recording(void* arg);
void handle_client(int new_socket);
void create_directory(const char* path);
void take_photo(ResponseData *response_data);
void start_video_recording();
void set_system_time(const char *date_time);
void get_system_time(ResponseData *response_data);
void send_response_to_client(int client_socket, int param);
void stop_recording();
int is_mp4_file(const char *filename);
//void find_latest_video(ResponseData *response_data);
//void find_earliest_and_latest_files(const char *directory);
VideoFilePaths find_earliest_and_latest_video_files(const char *directory);

#endif